package pers.hongze.test.contoller;

import org.springframework.stereotype.Controller;
import org.springframework.ui.ModelMap;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
@RequestMapping("/")
public class IndexContoller {

    @RequestMapping("index")
    public String index(ModelMap map){
        map.addAttribute("name", "test-thymeleaf");
        return "/index";
    }

    @RequestMapping("login")
    public String login(ModelMap map){
        map.addAttribute("name", "test-thymeleaf");
        return "/login";
    }
}
